﻿<Window x:Class="Workflow.CustomerDesigner.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="狼奔工作流设计器" Height="600" Width="1000">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition  Height="25"></RowDefinition>
            <RowDefinition Height="*"></RowDefinition>
            <RowDefinition Height="40"></RowDefinition>
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="200" MinWidth="100"></ColumnDefinition>
            <ColumnDefinition Width="*" MinWidth="300"></ColumnDefinition>
            <ColumnDefinition Width="280" MinWidth="100"></ColumnDefinition>
        </Grid.ColumnDefinitions>
        <GridSplitter HorizontalAlignment="Right" VerticalAlignment="Stretch" Width="5" Grid.Column="0" Grid.Row="1" Background="#FFEDEDED">

        </GridSplitter>
        <GridSplitter HorizontalAlignment="Left" VerticalAlignment="Stretch" Width="5" Grid.Row="1" Grid.Column="2" Background="#FFEDEDED">

        </GridSplitter>
        <StackPanel Grid.ColumnSpan="3">
            <Menu VerticalAlignment="Top" Height="25">
                <MenuItem Header="文件" >
                    <MenuItem Header="新建" Command="{Binding Path=NewCommand}">

                    </MenuItem>
                    <MenuItem Header="打开" 
                              Command="{Binding Path=OpenCommand}"/>
                    <Separator />
                    <MenuItem Header="保存" 
                              Command="{Binding Path=SaveCommand}"/>
                </MenuItem>
            </Menu>
        </StackPanel>
        <TabControl HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="0,0,5,0" Grid.Row="1" Grid.Column="0">
            <TabItem Header="工具箱">
                <ContentControl Content="{Binding ToolboxPanel}"></ContentControl>
            </TabItem>

        </TabControl>
        <TabControl HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="0,0,0,0" Grid.Row="1" Grid.Column="1">
            <TabItem Header="设计器">
                <ContentControl Content="{Binding WorkflowDesignerPanel}"></ContentControl>
            </TabItem>
            <TabItem Header="Xaml" GotFocus="TabItemGotFocusRefreshXamlBox">
                <TextBox Name="xmalTextBox" Text="{Binding XAML, Mode=OneWay}" AcceptsReturn="True"  VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto" IsReadOnly="True"></TextBox>
            </TabItem>
        </TabControl>
        <TabControl HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="5,0,0,0" Grid.Row="1" Grid.Column="2">
            <TabItem Header="属性">
                <ContentControl Content="{Binding WorkflowPropertyPanel}"></ContentControl>
            </TabItem>
        </TabControl>
    </Grid>
</Window>
